home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Loadstar 11
/
011.d81
/
recipe filer
(
.txt
)
< prev
next >
Wrap
Commodore BASIC
|
2022-08-26
|
4KB
|
128 lines
0 gosub60000
5 dima$(20),na$(1000),ni$(100),se$(100)
10 print"[158]";chr$(14):poke53280,15:poke53281,9
1000 rem recipe subroutine
1010 print"[147] [215]elcome to the [210]ecipe [198]iles[146]"
1020 print"[208]ress the highlighted[146] letter to:":goto1030
1025 na$="":nd$="":kl=0:print"[147][215]hich?"
1030 print"[215][146]rite a recipe
1035 [153]"(NULL)waitist the recipes on file
1036 print"[209][146]uit the program"
1040 geta$:ifa$="" then 1040
1045 fori=1to3:ifa$<>mid$("wlq",i,1)thennexti:goto1040
1050 m=i:i=3:nexti:onmgoto1060,1175,2000
1060 na$="": print"[147] [183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][145][145]"
1061 input"[206]ame of recipe";na$
1062 iflen(na$)=0then1060
1065 open2,8,2,"0:recipes,s,r"
1067 input#2,nm$
1070 iflen(nm$)=0then close2:goto1090
1075 ifnm$=na$thenclose2:goto1085
1077 ifnm$="end"then close2: goto 1090
1080 goto1067
1085 print"[212]here is already a recipe by this name on file. [195]ontinue (y/n)?"
1086 geta$:ifa$=""then1086
1087 ifa$="n"then1025
1088 ifa$<>"y"then1086
1090 fori=1ton:a$(i)="":nexti:n=0
1093 print" [217]ou may type up to 15 lines. [200]it return at the end of";
1095 print" each line.":print" [213]se no punctuation except . and ' as ";
1096 print"you type. [201]f you need to start over, type 'r' (return). [212]o ";
1097 print"end, hit return on an empty line"
1098 print
1100 print" [183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][145][145]"
1103 n=n+1:inputa$(n)
1105 if len(a$(n))=0 orn=15then1115
1107 ifa$(n)="r"then1060
1110 goto1100
1115 open15,8,15:print#15,"s8:"+na$:close 15
1120 open2,8,2,"0:"+na$+",s,w"
1125 print#2,na$:print#2," "
1130 fori=1 to n:print#2,a$(i):next i:print#2,"end"
1135 close 2
1140 k=0:l=0: open2,8,2,"0:recipes,s,r"
1145 k=k+1:input#2,d$
1150 ifd$="end"then1158
1151 input#2,na$(k)
1152 iflen(na$(k))=0then1158
1155 ifk=val(g$)thennc$=na$(k):na$(k)="":k=k-1:g$=""
1156 goto1145
1158 if kl=1thenopen15,8,15:print#15,"s8:"+nc$:close15
1159 close2: open15,8,15:print#15,"s8:recipes":close 15
1160 open2,8,2,"0:recipes,s,w":z$="."
1162 for i=1tok:ifna$(i)=na$thenl=1
1163 iflen(na$(i))=0thenk=k-1:goto1168
1165 print#2,str$(i)+z$:print#2,na$(i)
1166 nexti
1167 if kl=1then goto1170
1168 ifl<>1 thenprint#2,str$(k+1)+z$:print#2,na$
1170 :print#2,"end":close2: goto1600
1175 print"[204]ist of recipes on file:"
1176 open2,8,2,"0:recipes,s,r"
1179 input#2,e$:input#2,nd$:ife$="end"then1185
1181 z$=".":ife$=m$+z$thenclose2:goto 1205
1182 ife$<m$+z$ then1179
1183 print"";e$;:print nd$:goto1179
1185 close2
1187 ifnd$=""then print "[206]one on file yet":goto1025
1190 print"[210]ead a recipe (y/n)?"
1192 geta$:ifa$=""then1192
1194 ifa$= "n"then1700
1196 ifa$<>"y"then 1192
1200 print"[215]hich number";:inputm$:goto1176
1205 n=0:open2,8,2,"0:"+nd$+",s,r"
1215 n=n+1:input#2,a$(n)
1220 ifa$(n)="end" then1250
1230 goto 1215
1250 close 2
1260 print
1270 fori=1 ton:print"";a$(i):nexti
1300 m$="":print"[208]rint this recipe (y/n)?
1302 [161]a$:[139]a$[178]""[167]1302
1304 [139]a$[178]"n"[167]na$[178]nd$:[137]1600
1305 [139]a$[179][177]"y"[167]1302
1308 [153]"(NULL)urn on the printer and press p to print or n to stop"
1310 [161]a$:[139]a$[178]""[167]1310
1312 [139] a$[178]"n"[167]1500
1315 [139]a$[179][177]"p"[167]1310
1320 [160]3 :[159]1,4,4:[157]1:[153][199](27);[199](77);:[160]1:[159]1,4,7:[157]1
1325 [153]"(NULL)ecipe for: "; nd$:[153]
1330 [129]i[178]2 [164]n[171]1:[153]"";a$(i):[130]i
1350 [160]1:[159]3,3,1:[157]3
1500 [153]"atnnother copy (y/n)?"
1510 [161]a$:[139]a$[178]""[167]1510
1520 [139]a$[178]"n"[167] 1025
1530 [139]a$[179][177]"y"[167]1510
1540 [153]"check printer and press p to print or n to stop":[137]1310
1600 [153]"lenopy on backup disk (y/n)?"
1610 [161]a$:[139]a$[178]""[167]1610
1620 [139]a$[178]"n" [167] 1025
1630 [139]a$[179][177]"y"[167] 1610
1640 [153]"(NULL)ut backup disk in drive and press peek or (NULL) for stop"
1650 [161]a$:[139]a$[178]""[167]1650
1660 [139]a$[178]"n"[167]1025
1670 [139]a$[179][177]"b" [167] 1650
1680 [137]1115
1700 [153]"onstr$elete a recipe (y/n)?"
1710 [161]a$:[139]a$[178]""[167]1710
1720 [139]a$[178] "n"[167]1025
1730 [139]a$[179][177]"y"[167] 1710
1740 kl[178]1:[153]"(NULL)hich number";:[133]g$:[137]1140
2000 [153]"loadleft$appy eating!":[137]63000
60000 t$[178]" ":c[178]0:c$[178]"":[153]"load":[151]53281,0
60030 [153][166]7)""t$:[153][166]7)" (NULL)ecipe asciler wait"
60051 [153][166]7)""t$:[153]:[153][163]18)"by"
60060 [153]:[153][166]14)"str$ick lenaron"
60070 [153]:[153][166]12)"lenopyright 1985"
60080 [153]:[153]:[153]:[153]" (NULL)(NULL)atnstr$(NULL)(NULL)atn(NULL) is not public domain."
60090 [153]:[153]" (NULL)lease respect the author's rights."
60100 [153]:[153]" (NULL)ress space bar to continue."
60110 [129]cc[178]1[164]48:[161]k$:[139]k$[178]" "[167]60130
60120 [139]cc[178]1[167][153][202](c$,c[170]2,1)"onon";:c[178][168](c)
60125 [130]:[137]60100
60130 [153]c$:[142]
63000 [143] connect back to loadstar
63005 [129]dl[178]1[164]3000:[130]
63010 [153]"loadload"[199](34)"payload"[199](34)",8":[153]"run"
63020 [151]631,13:[151]632,13:[151]198,2:[128]